<?php if($data):?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>“拔尖计划”师生活动情况表</title>
<object id="WebBrowser" classid=CLSID:8856F961-340A-11D0-A96B-00C04FD705A2 height="0" width="0">
</object>

<style media=print>
.Noprint {
	display:none;
}
</style>
<style>
.PageNext {
	page-break-before: auto;
	page-break-after: always;
}

table{
	border-collapse:collapse;
	border-spacing:0;
	border-left:1px solid #000;
	border-top:1px solid #000;
	background:white;
}
th,td{
	border-right:1px solid #000;
	border-bottom:1px solid #000;
	padding:5px 15px;
}
th{
	font-weight:bold;
	background:white;
}
<!--
控制分页--> .style8 {
	font-size: medium;
	color: #000066;
}
</style>
</head><script language="javascript"> 
function printsetup(){ 

		document.all.WebBrowser.execwb(8,1); 
} 
	function printpreview(){ 
	// 打印页面预览 
	var mStr1,mStr2,mStr3;   
	mStr1 = document.body.innerHTML ;  
	mStr2= mStr1; 
	mStr3= mStr1;
	var mWindow = window; 
	
	
	mWindow.document.body.innerHTML=mStr2;
	var lian=mWindow.document.getElementById("lian");
	
	lian.innerHTML="<p>第二联</p>";
	
	lian.setAttribute("id","lian1");
	
	
	mStr2=mWindow.document.body.innerHTML;
	
	
	mWindow.document.body.innerHTML=mStr3;
	var lian=mWindow.document.getElementById("lian");
	
	lian.innerHTML="<p>第三联</p>";
	
	lian.setAttribute("id","lian2");
	
	
	mStr3=mWindow.document.body.innerHTML;
	
	mWindow.document.body.innerHTML=mStr1+mStr2+mStr3;
	
	mWindow.document.all.WebBrowser.execwb(7,1);   
	window.document.body.innerHTML = mStr1;
	
	} 
	function printit() 
	{ 
	if (confirm("确定打印吗？")) {
		var mStr1,mStr2,mStr3;   
	mStr1 = document.body.innerHTML ;  
	mStr2= mStr1; 
	mStr3= mStr1;
	var mWindow = window; 
	
	
	mWindow.document.body.innerHTML=mStr2;
	var lian=mWindow.document.getElementById("lian");
	
	lian.innerHTML="<p>第二联</p>";
	
	lian.setAttribute("id","lian1");
	
	
	mStr2=mWindow.document.body.innerHTML;
	
	
	mWindow.document.body.innerHTML=mStr3;
	var lian=mWindow.document.getElementById("lian");
	
	lian.innerHTML="<p>第三联</p>";
	
	lian.setAttribute("id","lian2");
	
	
	mStr3=mWindow.document.body.innerHTML;
	
	mWindow.document.body.innerHTML=mStr1+mStr2+mStr3;
		
		mWindow.document.all.WebBrowser.execwb(6,6);   
		window.document.body.innerHTML = mStr1;			
	} 
} 
</script>
<body>
<div class="PageNext">
  <div align="center">
    <h2 class="style4">“拔尖计划”师生活动情况表</h2>
    <form id="form1" name="form1" method="post" action="">
      <input class="Noprint" type=button name=button_print value="打印" class="noprint" onclick="javascript:printit()"/>
      <input class="Noprint" type=button name=button_setup value="打印页面设置" class="noprint" onclick="javascript:printsetup();"/>
      <input class="Noprint" type=button name=button_show value="打印预览" class="noprint" onclick="javascript:printpreview();"/>
        <table width="1100" border="1" align="center" cellpadding="5" cellspacing="1" bgcolor="#ffffff" >
              <tr>
                <td width="70px"><span class="font_foot STYLE7">活动类型</span></td>
                <td width="50px"><span class="font_foot STYLE7">子类型</span></td>
                <td width="50px"><span class="font_foot STYLE7">主办院系</span></td>
                <td width="50px"><span class="font_foot STYLE7">活动名称</span></td>
                <td width="50px"><span class="font_foot STYLE7">主讲人/主持人</span></td>
                <td width="50px"><span class="font_foot STYLE7">开始时间</span></td>
                <td width="50px"><span class="font_foot STYLE7">结束时间</span></td>
                <td width="50px"><span class="font_foot STYLE7">地点</span></td>
                <td width="50px"><span class="font_foot STYLE7">内容简介</span></td>
                <td width="50px"><span class="font_foot STYLE7">经费预算</span></td>
                <td width="50px"><span class="font_foot STYLE7">活动申请人</span></td>
              </tr>
              <?php if(count($data['items'])>0):?>
              	<?php foreach($data['items'] as $activity):
              //	$activity = new ActivityBean();
              	?>
              <tr>
                <td width="70px"><span class="font_foot STYLE7"><?php echo getActivityType($activity->activityType);?></span></td>
                <td><?php echo getActivitySubType($activity->type);?></td>
                <td><?php echo getInstitute($activity->department);?></td>
                <td><?php echo $activity->name;?></td>
                <td><?php echo $activity->host;?></td>
                <td><?php echo date("Y年m月d日",strtotime($activity->activityBegin));?></td>
                <td><?php echo date("Y年m月d日",strtotime($activity->activityEnd));?></td>
                <td><?php echo $activity->location?></td>
                <td><?php $activity->content;?></td>
                <td><?php echo $activity->budget;?></td>
                <td><?php echo $activity->department;?></td>
              </tr>
              <?php endforeach;?>
              <?php endif;?>
            </table>
    </form>
  </div>
</div>
</body>
</html>
<?php endif;?>